import 'package:tin_flutter/generated/json/base/json_field.dart';
import 'package:tin_flutter/generated/json/home_content_entity.g.dart';
import 'dart:convert';
export 'package:tin_flutter/generated/json/home_content_entity.g.dart';

@JsonSerializable()
class HomeContentEntity {
	List<HomeContentAdvertiseList> advertiseList = [];
	List<HomeContentBrandList> brandList = [];
	late HomeContentHomeFlashPromotion homeFlashPromotion;
	List<HomeContentNewProductList> newProductList = [];
	List<HomeContentHotProductList> hotProductList = [];
	List<dynamic> subjectList = [];

	HomeContentEntity();

	factory HomeContentEntity.fromJson(Map<String, dynamic> json) => $HomeContentEntityFromJson(json);

	Map<String, dynamic> toJson() => $HomeContentEntityToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeContentAdvertiseList {
	int id = 0;
	String name = '';
	int type = 0;
	String pic = '';
	String startTime = '';
	String endTime = '';
	int status = 0;
	int clickCount = 0;
	int orderCount = 0;
	String url = '';
	int sort = 0;

	HomeContentAdvertiseList();

	factory HomeContentAdvertiseList.fromJson(Map<String, dynamic> json) => $HomeContentAdvertiseListFromJson(json);

	Map<String, dynamic> toJson() => $HomeContentAdvertiseListToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeContentBrandList {
	int id = 0;
	String name = '';
	String firstLetter = '';
	int sort = 0;
	int factoryStatus = 0;
	int showStatus = 0;
	int productCount = 0;
	int productCommentCount = 0;
	String logo = '';
	String bigPic = '';
	String brandStory = '';

	HomeContentBrandList();

	factory HomeContentBrandList.fromJson(Map<String, dynamic> json) => $HomeContentBrandListFromJson(json);

	Map<String, dynamic> toJson() => $HomeContentBrandListToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeContentHomeFlashPromotion {
	String startTime = '';
	String endTime = '';
	String nextStartTime = '';
	String nextEndTime = '';
	List<HomeContentHomeFlashPromotionProductList> productList = [];

	HomeContentHomeFlashPromotion();

	factory HomeContentHomeFlashPromotion.fromJson(Map<String, dynamic> json) => $HomeContentHomeFlashPromotionFromJson(json);

	Map<String, dynamic> toJson() => $HomeContentHomeFlashPromotionToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeContentHomeFlashPromotionProductList {
	int id = 0;
	int brandId = 0;
	int productCategoryId = 0;
	int feightTemplateId = 0;
	int productAttributeCategoryId = 0;
	String name = '';
	String pic = '';
	String productSn = '';
	int deleteStatus = 0;
	int publishStatus = 0;
	int newStatus = 0;
	int recommandStatus = 0;
	int verifyStatus = 0;
	int sort = 0;
	int sale = 0;
	double price = 0.0;
	int giftGrowth = 0;
	int giftPoint = 0;
	int usePointLimit = 0;
	String subTitle = '';
	double originalPrice = 0.0;
	int stock = 0;
	int lowStock = 0;
	String unit = '';
	double weight = 0.0;
	int previewStatus = 0;
	String serviceIds = '';
	String keywords = '';
	String note = '';
	String albumPics = '';
	String detailTitle = '';
	int promotionPerLimit = 0;
	int promotionType = 0;
	String brandName = '';
	String productCategoryName = '';
	String description = '';
	double promotionPrice = 0.0;
	String promotionStartTime = '';
	String promotionEndTime = '';

	HomeContentHomeFlashPromotionProductList();

	factory HomeContentHomeFlashPromotionProductList.fromJson(Map<String, dynamic> json) => $HomeContentHomeFlashPromotionProductListFromJson(json);

	Map<String, dynamic> toJson() => $HomeContentHomeFlashPromotionProductListToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeContentNewProductList {
	int id = 0;
	int brandId = 0;
	int productCategoryId = 0;
	int feightTemplateId = 0;
	int productAttributeCategoryId = 0;
	String name = '';
	String pic = '';
	String productSn = '';
	int deleteStatus = 0;
	int publishStatus = 0;
	int newStatus = 0;
	int recommandStatus = 0;
	int verifyStatus = 0;
	int sort = 0;
	int sale = 0;
	double price = 0.0;
	int giftGrowth = 0;
	int giftPoint = 0;
	int usePointLimit = 0;
	String subTitle = '';
	double originalPrice = 0.0;
	int stock = 0;
	int lowStock = 0;
	String unit = '';
	double weight = 0.0;
	int previewStatus = 0;
	String serviceIds = '';
	String keywords = '';
	String note = '';
	String albumPics = '';
	String detailTitle = '';
	int promotionPerLimit = 0;
	int promotionType = 0;
	String brandName = '';
	String productCategoryName = '';
	String description = '';

	HomeContentNewProductList();

	factory HomeContentNewProductList.fromJson(Map<String, dynamic> json) => $HomeContentNewProductListFromJson(json);

	Map<String, dynamic> toJson() => $HomeContentNewProductListToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeContentHotProductList {
	int id = 0;
	int brandId = 0;
	int productCategoryId = 0;
	int feightTemplateId = 0;
	int productAttributeCategoryId = 0;
	String name = '';
	String pic = '';
	String productSn = '';
	int deleteStatus = 0;
	int publishStatus = 0;
	int newStatus = 0;
	int recommandStatus = 0;
	int verifyStatus = 0;
	int sort = 0;
	int sale = 0;
	double price = 0.0;
	int giftGrowth = 0;
	int giftPoint = 0;
	int usePointLimit = 0;
	String subTitle = '';
	double originalPrice = 0.0;
	int stock = 0;
	int lowStock = 0;
	String unit = '';
	double weight = 0.0;
	int previewStatus = 0;
	String serviceIds = '';
	String keywords = '';
	String note = '';
	String albumPics = '';
	String detailTitle = '';
	int promotionPerLimit = 0;
	int promotionType = 0;
	String brandName = '';
	String productCategoryName = '';
	String description = '';

	HomeContentHotProductList();

	factory HomeContentHotProductList.fromJson(Map<String, dynamic> json) => $HomeContentHotProductListFromJson(json);

	Map<String, dynamic> toJson() => $HomeContentHotProductListToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}